package com.api.shopapi.service.impl;


import com.api.shopapi.entity.BusinessRel;
import com.api.shopapi.mapper.BusinessRelMapper;
import com.api.shopapi.service.BusinessRelService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("BusinessRelServiceImplOne")
public class BusinessRelServiceImpl implements BusinessRelService {

    @Autowired
    private BusinessRelMapper businessRelMapper;

    @Override
    public int insert(BusinessRel businessRel){
        return businessRelMapper.insert(businessRel);
    }

    @Override
    public int deleteByBusinessRelCode(String businessRelCode){
        return businessRelMapper.deleteByBusinessRelCode(businessRelCode);
    }

    @Override
    public int updateByBusinessRelCode(BusinessRel businessRel){
        return businessRelMapper.updateByBusinessRelCode(businessRel);
    }

    @Override
    public BusinessRel getByBusinessRelCode(String businessRelCode){
        return businessRelMapper.getByBusinessRelCode(businessRelCode);
    }

    @Override
    public BusinessRel getByBusinessCode(String businessCode){
        return businessRelMapper.getByBusinessCode(businessCode);
    }

    @Override
    public List<BusinessRel> getList(){
        return businessRelMapper.getList();
    }

    @Override
    public List<BusinessRel> getListByBusinessTopCode(String businessTopCode){
        return businessRelMapper.getListByBusinessTopCode(businessTopCode);
    }


}
